<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    用户名<input type="txtx" name="1" class="11">
    <br>
    密码  <input type="passwrod" name="2" id="" class="22">
    <br>
    性别  <input type="radio" name="3" id="" class="33">男   <input type="radio" class="33">   女
    <br>
    学院  <input type="text" name="4" id="" class="44">
    <br>
    爱好  <input type="checkbox" name="5" id="" class="55"> 按摩  <input type="checkbox" name="" id="" class="55"> 游泳
    <br>
    自我介绍 <textarea rows="10" cols="30" name="6" class="66">
        
        </textarea>
     <button type="button">提交</button>
          


</body>
   <script>
       //naem
       var  aa=document.getElementsByName(1)
       console.log(aa)
       var  bb=document.getElementsByName(2)
       console.log(bb)
       var  cc=document.getElementsByName(3)
       console.log(cc)
       var  dd=document.getElementsByName(4)
       console.log(dd)
       var  ee=document.getElementsByName(5)
       console.log(ee)
       var  ff=document.getElementsByName(6)
       console.log(ff)
       //class
       var  aa1=document.getElementsByClassName('11')
       console.log(aa1)
       var  aa2=document.getElementsByClassName('22')
       console.log(aa2)
       var  aa3=document.getElementsByClassName('33')
       console.log(aa3)
       var  aa4=document.getElementsByClassName('44')
       console.log(aa4)
       var  aa5=document.getElementsByClassName('55')
       console.log(aa5)
       var  aa6=document.getElementsByClassName('66')
       console.log(aa6)
   </script>
</html>